import request from "@/common/request"

export function getOptionsCountApplet(userId) {
    return request({
        url: '/v1/user/getOptionsCountApplet',
        method: 'get',
		data:{
			userId:userId
		}
    })
}

export function getUserInfoById(userId) {
    return request({
        url: '/v1/user/info',
        method: 'get',
		data:{
			userId:userId
		}
    })
}



/**
 * 根据能量降序排
 * @param data
 * @returns {*}
 */
export function getUserByLevelDesc(data) {
    return request({
        url: '/member/user/getUserByLevelDesc',
        method: 'get',
        data: data
    })
}

/**
 * 根据炭币降序排
 * @param data
 * @returns {*}
 */
export function getUserByPointDesc(data) {
    return request({
        url: '/member/user/getUserByPointDesc',
        method: 'get',
        data: data
    })
}


/**
 * 获取个人签到排名信息
 * @param data
 * @returns {*}
 */
export function getSignRecordRanking() {
    return request({
        url: '/member/user/ranking',
        method: 'get',
    })
}

/**
 * 获取个人能量排名信息
 * @param data
 * @returns {*}
 */
export function getSignRecordEnergy() {
    return request({
        url: '/member/user/energy',
        method: 'get',
    })
}
/**
 * 修改用户信息
 * 
 * @param {Object} data
 */
export function updateUserInfo(data) {
    return request({
        url: '/member/user/update',
        method: 'put',
		data:data
    })
}
